<!--<table border="0" class="list">
<caption>需求信息</caption>
<tbody>
<tr class="nobg">
	<th>单号</th>
	<th>部门</th>
	<th>用户</th>
	<th>审批状态</th>
	<th>采购类型</th>
	<th>总数量</th>
	<th>时间</th>
</tr>
<tr>
	<td><?$demand.sno?></td>
	<td><?$demand.dept_name?></td>
	<td><?$demand.user_name?></td>
	<td class="state"><?= DemandHelper::flow2text($demand.audit_flow) ?></td>
	<td class="state"><?= DemandHelper::type2text($demand.type) ?></td>
	<td class="decimal"><?$demand.amount?></td>
	<td class="nowrap"><?=date('Y/m/d H:i', $demand.addtime)?></td>
</tr>
</tbody></table>-->

<table class="ptop" border="0" cellpadding="4" cellspacing="0" width="100%">
    <{if isprint() }>
         <thead>
            <tr class="nobg">
                <th colspan="4"><h2><?$print_com_name?></h2></th>
            </tr>
            <tr class="nobg">
                <th colspan="4"><h1><?$page_title?></h1></th>
            </tr>
        </thead>
   <{/if}>
    <tbody>
    <tr>
            <td width="80" valign="top">部门：</td>
            <td valign="top"><?$demand.dept_name?></td>
            <td width="15%" class="right">单号：</td>
            <td width="35%"><? $demand.sno ?></td>
    </tr>
    <tr>
            <td class="">采购类型：</td>
            <td><?= DemandHelper::type2text($demand.type) ?></td>
            <td width="15%" class="right">日期：</td>
            <td><?= date('Y-m-d H:i', $demand.addtime) ?></td>
    </tr>
    </tbody>
</table>

<table border=0 class="list pcontent" width="100%">
    <thead>
    <tr class="nobg">
            <th>材料编号</th>
            <th>材料名称</th>
            <th>品牌</th>
            <th>规格</th>
            <th>单位</th>
            <{if $demand.type==0}>
            <th>结存数量</th>
	    <th>最低库存</th>
            <{/if}>
            <th>采购数量</th>
            <th>用途</th>
            <th>备注</th>
    <{if !isprint() && $demand.audit_flow==1}>
            <th class="state">状态</th>
            <th class="state">说明</th>
    <{/if}>
    </tr>
    </thead>
    <tbody>
    <{foreach item=ware from=$demand.items}>
            <tr>
                    <td><{$ware.sno}></td>
                    <td><{$ware.name}></td>
                    <td><{$ware.brand}></td>
                    <td><{$ware.specific}></td>
                    <td><{$ware.unit}></td>
                    <{if $demand.type==0}>
                    <td class="decimal"><{$ware._amount}></td>
                    <td class="decimal"><{$ware.cordon}></td>
                    <{/if}>
                    <td class="decimal"><{$ware.amount}></td>
                    <td width="100"><{$ware.remark_use}></td>
                    <td><{$ware.remark}></td>
    <{if !isprint() && $demand.audit_flow==1}>
                    <td class="state"><?=DemandHelper::state2text($ware.state) ?></td>
                    <td>
                            <{if $ware.state==9}>
                            <div class="text"><{$ware.feedback}></div>
                            <{/if}>
                    </td>
    <{/if}>
            </tr>
    <{/foreach}>
    </tbody>
</table>
